package com.example.checkin.vn.home;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.ImageView;

import com.example.checkin.vn.MainActivity;
import com.example.checkin.vn.R;

public class FragmentHome extends Fragment {
	private static FragmentHome fragment = null;

	public static FragmentHome getInstance() {
		if (fragment == null) {
			fragment = new FragmentHome();
		}
		return fragment;
	}

	@Override
	public View onCreateView(LayoutInflater inflater, ViewGroup container,
			Bundle savedInstanceState) {
		View view = inflater.inflate(R.layout.fragment_home, container, false);
		ImageView imgHotel = (ImageView) view.findViewById(R.id.btnHotel);
		imgHotel.setOnClickListener(new OnClickListener() {

			@Override
			public void onClick(View arg0) {
				MainActivity.callbackClick.getResult(R.id.right_khachsan, "");
			}
		});
		return view;
	}
}
